package com.bw.shop2208a.entity

import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey
import java.io.Serializable

data class UserResult(
    val code: Int,
    val `data`: DataUserResult,
    val message: String
)
//数据库中不支持Any类型，需要改为可空的指定类型
@Entity(tableName = "user_info")
data class DataUserResult (
    val address: String,
    val admin: Boolean,
    val birth: String,
    val coinCount: Int,
    val email: String?,
    val icon: String,
    @PrimaryKey//autoGenerate自增
    val id: Int,
    @ColumnInfo(name = "nick_name")
    val nickname: String,
    val password: String,
    val publicName: String?,
    val sex: String,
    val token: String,
    val type: Int,
    val username: String
): Serializable